home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Delphi Programmer's Power Pack
/
Delphi Volume 1.iso
/
s_to_z
/
tpop3
/
mailbase.int
< prev
next >
Wrap
Text File
|
1996-09-15
|
2KB
|
60 lines
unit mailbase;
interface
uses
Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
ExtCtrls, MailUtil, WinSock;
type
EMailError = class(Exception);
ESocketError = class(Exception);
TMailBase = class(TComponent)
private
{ Private declarations }
FServer : string;
FTimeOut : Integer;
FLogFileName : string;
FDefaultPort : word;
protected
{ Protected declarations }
MyWSAData : WSAData;
TheSocket : TSocket;
ServerInAddr : PIn_Addr;
ServerIPAddr : string;
ThePort : word;
Timer : TTimer;
CurTick : Integer;
WsInitCount : Integer;
Log : TStrings;
TimedOut : boolean;
Canceled : boolean;
ServiceName : string;
procedure TimerOnTimer(Sender : TObject);
procedure TimerOn;
procedure TimerOff;
procedure ReInit; virtual;
procedure ResolveRemoteHost;
procedure GetService;
procedure OpenSocket;
procedure Connect;
public
{ Public declarations }
constructor Create(AOwner : TComponent); override;
destructor Destroy; Override;
procedure WriteLogFile;
procedure Cancel; virtual;
procedure Open; virtual; {11.4}
procedure Close; virtual;
property LogFileName : string read FLogFileName write FLogFileName;
property DefaultPort : word read FDefaultPort write FDefaultPort;
published
{ Published declarations }
property Server : string read FServer write FServer;
property TimeOut : Integer read FTimeOut write FTimeOut default 60;
end;
implementation